import BasicLayout from '@c/Layout/BasicLayout'
import BasicLayoutGroup from '@c/Layout/BasicLayoutGroup'

const homeComponent = window.config.VUE_APP_HOME ? window.config.VUE_APP_HOME : 'HomeMain1'

export const asyncRouterMap = [
  {
    path: '/',
    name: 'index',
    component: BasicLayout,
    redirect: '/home',
    children: []
  }
]
/**
 * 基础路由
 */
export const constantRouterMap = [
  {
    path: '/defaultPage',
    name: 'defaultPage',
    component: () => import('@/views/defaultPage/DefaultPage')
  },
  {
    path: '/home',
    name: 'home',
    component: () => import('@/views/home/' + homeComponent)
  },
  {
    path: '/investment',
    name: 'investment',
    component: BasicLayoutGroup,
    redirect: '/investment/matterManage',
    children: [
      {
        path: '/investment/matterManage',
        name: 'matterManage',
        component: () => import('@/views/investmentOnline/investmentPlatform/BusinessItemConfigure'),
        meta: {
          title: '业务事项配置',
          name: 'matterManage',
          group: '402886e28947d02d0189539058390328'
        }
      }
    ]
  },
  {
    path: '/404',
    name: '404',
  }
]
